package sennetworkserver;

import java.util.ArrayList;

public class LaneStore {	
	
	private static ArrayList<Lane> lanes = new ArrayList<Lane>();

	static {		
		for(int i = 1; i <= 28; i++) {
			lanes.add(new Lane(i));
		}
		System.out.println("Lanes Created");
	}
	
	private LaneStore() { }
	
	public static Lane getLane(int id) {
		if(id < 0 || id > 28) 
			return null;
		if (id == 0) id = 28;
		return lanes.get(id-1);
	}
	
	public static ArrayList<Lane> getAllLanes() {
		return lanes;
	}
}
